<div class="top">
<?php if (!empty($this->catalogRow->catalog_image_id)):?>
	<div class="image">
		<?php $catalogImageName = $this->logoFromRowset($this->catalogRow->catalog_image_id, $this->imagesRowset)?>
		<img alt="Logo, <?php print $this->escape($this->catalogRow->name) ?>" src="<?php print $this->url(array('type' => "logo1", 'file' => $catalogImageName),'catalogImage');?>" />
	</div>
<?php endif;?>
	
	<div class="text">
		<?php print $this->partial('index/show/description.phtml', $this)?>
    </div>
</div>

<div class="sub">
	<div class="left">
		<div class="sinner">
			<h3 class="iconbg timer">Godziny otwarcia:</h3>
			
			<?php if (count($this->timeRow)):?>
			<dl class="list-info">
				<?php
					// dni tygodnia
					$m = array(
						1 => 'Poniedziałek',
						2 => 'Wtorek',
						3 => 'Środa',
						4 => 'Czwartek',
						5 => 'Piątek',
						6 => 'Sobota',
						7 => 'Niedziela'
					);
				?>
				<?php foreach($m as $i => $day):?>
				<?php if (isset($this->timeRow[$i])):?>
					<dt><?php print $day?></dt>
					<dd>
					<?php foreach ($this->timeRow[$i] as $time):?>
						<span>od <?php print $time['start']?> do <?php print $time['end']?></span>
					<?php endforeach;?>
					</dd>
				<?php endif;?>
				<?php endforeach;?>
			</dl>
			<?php else:?>
			<p class="msg-info">W aktualizacji</p>
			<?php endif;?>
		</div>
	</div>

	<div class="center">
    	<div class="sinner">
	    	<h3 class="iconbg contact">Kontakt:</h3>
			<?php print $this->partial('index/show/contact.phtml', $this)?>
			
		</div>
		<div class="bottom">
			<p class="social">
				<?php
					$body = $this->escape($this->catalogRow->name) . "  " . $this->url(array())
				?>
				<b>Info dla znajomych:</b>
				<script type="text/javascript">
					document.write('<a target="_blank" rel="nofallow" href="' + 'http://www.facebook.com/share.php?u=' + '<?php print $this->url(array())?>' + '&t=' + '<?php print $this->escape($this->catalogRow->name)?>' + '">' +
							'<img src="http://www.facebook.com/favicon.ico" title="Podziel sie z znajomymi na Facebook" /></a>');
					
					document.write('<a target="_blank" rel="nofallow" href="' + 'http://blip.pl/dashboard?body=' + '<?php print $body; ?>' + '">' +
					'<img src="http://blip.pl/images/favicon.gif" title="Podziel sie z znajomymi na Blipie" /></a>');
			
					document.write('<a target="_blank" rel="nofallow" href="' + 'http://nasza-klasa.pl/sledzik?shout=' + '<?php print $body; ?>' + '">' +
					'<img src="http://nasza-klasa.pl/favicon.ico" title="Podziel sie z znajomymi na Naszej klasie" /></a>');
				</script>
			
				<noscript>
					<a  target="_blank" rel="nofallow" href="http://www.facebook.com/share.php?u=<?php print $this->url(array())?>&t=<?php print $this->escape($this->catalogRow->name)?>">
						<img src="http://www.facebook.com/favicon.ico" title="Podziel sie z znajomymi na Facebook" /></a>
					<a  target="_blank" rel="nofallow" href="http://blip.pl/dashboard?body=<?php print $body; ?>">
						<img src="http://blip.pl/images/favicon.gif" title="Podziel sie z znajomymi na Blipie" /></a>
					<a  target="_blank" rel="nofallow" href="http://nasza-klasa.pl/sledzik?shout=<?php print $body; ?>">
						<img src="http://nasza-klasa.pl/favicon.ico" title="Podziel sie z znajomymi na Naszej klasie" /></a>
				</noscript>
			</p>
		</div>
	</div>
	<div class="right">
		<div class="sinner">
    		<h3 class="iconbg infor">Gabinet zapewnia:</h3>

			<?php if (count($this->optionsRowset) > 0):?>
				<ul id="optionsList" class="options small">
				<?php foreach ($this->optionsRowset as $option): ?>
					<li><?php print $this->escape($option['name'])?></li>
				<?php endforeach;?>
				</ul>
			<?php else:?>
				<p class="msg-info">W aktualizacji</p>
			<?php endif;?>
			
			<?php if ($this->certificated):?>
			<div id="certyfikat">
				<a href="<?php print $this->url(array('id' => $this->catalogRow->id),'catalog-certificate')?>">
					<img src="<?php print sprintf('%s/certyfikaty/%s/%s.png',
					$this->baseUrl(), CATALOG_TYPE, 'medium1')?>" alt="Certyfikat zaufania dla <?php print $this->catalogRow->name?>" /></a>
			</div>
			<?php endif;?>
			
		</div>
	</div>
</div>